const express = require('express');
const router = express.Router();
const userinfo_handler = require('../router_handler/userinfo')

const expressJoi = require('@escook/express-joi');
const { update_scheme,update_password_scheme,update_avatar_scheme} = require('../schedule/index')

router.get('/userinfo',userinfo_handler.getuserinfo)
router.post('/userinfo',expressJoi(update_scheme),userinfo_handler.updateuserinfo)
router.post('/userinfo_password',expressJoi(update_password_scheme),userinfo_handler.updatepassword)
router.post('/userinfo_avatar',expressJoi(update_avatar_scheme),userinfo_handler.update_avatar)

module.exports = router;